<?php
header("Content-Type:text/xml");
echo'<?xml version="1.0" encoding="utf-8" standalone="yes" ?>';
echo '<response>';
date_default_timezone_set("Asia/shanghai");
$today = date("Y-m-d H:i:s");
$todaydd = date("Y-m-d l H:i:s");
//$target =date("Y-m-d H:i:s",mktime(0,0,0,1,15,2011));
$target = date("Y-m-d H:i:s",mktime(10,1,0,3,3,2011));
$lasttime = strtotime($target)-strtotime($today);
$allhours =$lasttime/3600;
$alldays =floor($allhours/24);
$temphour =$allhours%24;
$tempminutes =($lasttime/60)%(24*60)%60;
$tempseconds =$lasttime%(24*60*60)%60%60;
echo '<days>'.$alldays.'</days>';
echo '<hour>'.$temphour.'</hour>';
echo '<minute>'.$tempminutes.'</minute>';
echo '<seconds>'.$tempseconds.'</seconds>';
echo '<today>'.$todaydd.'</today>';
echo '<today>'.$target.'</today>';
echo '</response>';
?>

